package com.uzai.console.service.locallive;

import com.uzai.console.dto.locallive.elmorder.ElmOrderDownLoadDto;
import com.uzai.console.entity.ElmOrder;

import java.util.List;

/***
 * @Auther: liuqi
 * @Date: 2021/08/27 11:23
 * @Description:
 */
public interface ElmOrderSyncService {

    /**
     * 手动下载所有单个饿了么联盟订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param elmOrderDownLoadDto
     * @return null
     */
    void downloadOrder(ElmOrderDownLoadDto elmOrderDownLoadDto, Long tbTokenId);

    /**
     * 手动下载所有单个饿了么联盟订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param elmOrderDownLoadDto
     * @return null
     */
    void downloadOrderListSync(ElmOrderDownLoadDto elmOrderDownLoadDto);

    /**
     * 远程调用订单库API，手动下载饿了么订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param elmOrder
     * @return null
     */
    void updateElmOrder(ElmOrder elmOrder);

    /**
     * 远程调用订单库API，更新7天前未收货订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @return null
     */
    void updateElmOrderUnReceivedListSync(Long merId);

    /**
     * 修改饿了么未收货订单为已结算(只改订单状态)
     *
     * @param merId
     * @param day
     * @param status 订单修改之后的状态（2-失效；1-结算）
     * @return null
     * @author liuqi
     * @date 2021/8/13 11:38
     */
    void uploadElmOrderSettingSync(Long merId, int day, int status, List<Integer> sourceStatus);

    /**
     * 远程调用订单库API，更新day天前未收货订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param day
     * @return null
     */
    void updateElmOrderUnReceivedListSync(Long merId, int day);

    /**
     * 远程调用订单库API，更新day天前订单-已冻结
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param day
     * @return null
     */
    void updateElmOrderFreezedListSync(Long merId, int day);

    /**
     * 远程调用订单库API，更新day天前未收货订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderUnReceivedListSync(Long merId, Integer startTime, Integer endTime, Long userId);

    /**
     * 直接结算，更新day天前未收货订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderUnReceivedListSync_settle(Long merId, Integer startTime, Integer endTime, Long userId);

    /**
     * 远程调用订单库API，更新day天前订单-已冻结
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderFreezedListSync(Long merId, Integer startTime, Integer endTime, Long userId);

    /**
     * 直接结算，更新day天前已冻结订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderFreezedListSync_settle(Long merId, Integer startTime, Integer endTime, Long userId);


    /**
     * 远程调用订单库API，更新day天前维权中订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param day
     * @return null
     */
    void updateElmOrderRefundingListSync(Long merId, int day);

    /**
     * 远程调用订单库API，更新day天前订单-维权中
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderRefundingListSync(Long merId, Integer startTime, Integer endTime, Long userId);

    /**
     * 直接结算，更新day天前维权中订单
     * @author liuqi
     * @date 2021/8/13 11:38
     * @param merId
     * @param startTime
     * @return null
     */
    void updateElmOrderRefundingListSync_settle(Long merId, Integer startTime, Integer endTime, Long userId);

}
